package cn.edu.cug.cs.gtl.apis.ui;

import cn.edu.cug.cs.gtl.apis.render.Factory;
import cn.edu.cug.cs.gtl.apis.render.Render;
import cn.edu.cug.cs.gtl.apis.render.viewers.Viewer;
import cn.edu.cug.cs.gtl.protos.Layer;
import cn.edu.cug.cs.gtl.protos.Map;
import cn.edu.cug.cs.gtl.protos.Project;
import org.pf4j.PluginManager;

public abstract class AbstractApplication {
    protected AbstractFrame mainWindow = null;
    protected Project project=null;
    protected Map currentMap=null;
    protected Layer currentLayer=null;

    protected Factory factory = null;

    protected  PluginManager pluginManager=null;


    public Project getProject(){
        return this.project;
    }

    public void setProject(Project p){
        this.project=p;
    }

    public Factory getFactory() {
        return factory;
    }

    public Map getCurrentMap() {
        return currentMap;
    }

    public void setCurrentMap(Map currentMap) {
        this.currentMap = currentMap;
    }

    public Layer getCurrentLayer() {
        return currentLayer;
    }

    public void setCurrentLayer(Layer currentLayer) {
        this.currentLayer = currentLayer;
    }

    public AbstractFrame getMainFrame() {
        return mainWindow;
    }

    public abstract Render getRender();

    public abstract Viewer getViewer();

    public PluginManager getPluginManager(){
        return this.pluginManager;
    }

    public void setPluginManager(PluginManager pluginManager){
        this.pluginManager=pluginManager;
    }
}
